package com.lh.自己动手写RPC;

import com.lh.自己动手写RPC.MyService.CheckService;
import com.lh.自己动手写RPC.MyService.ICheckService;

import java.io.IOException;
import java.net.InetSocketAddress;

/**
 * 作者：idea
 * 日期：2018/7/2
 * 描述：
 */
public class Test {
    public static void main(String[] args) {
        new Thread(new Runnable() {
            @Override
            public void run() {
                Server server=new ServerCenter(8088);
                server.register(HelloService.class,HelloServiceImpl.class);
                server.register(ICheckService.class, CheckService.class);
                try {
                    server.start();
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
        }).start();
        System.out.println("this server is start!");

    }
}
